<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml">
		<head>
			<!-- template designed by Marco Von Ballmoos -->
			<title>Docs For Class FormAPI</title>
			<link rel="stylesheet" href="../media/stylesheet.css" />
			<meta http-equiv='Content-Type' content='text/html; charset=iso-8859-1'/>
		</head>
		<body>
			<div class="page-body">			
<h2 class="class-name">Class FormAPI</h2>

<a name="sec-description"></a>
<div class="info-box">
	<div class="info-box-title">Description</div>
	<div class="nav-bar">
					<span class="disabled">Description</span> |
															<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
						
					</div>
	<div class="info-box-body">
        		<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Control object, that generates the HTML code and handle requests from clients.</p>
	<ul class="tags">
				<li><span class="field">property:</span> <a href="../formapi/Form.html">Form</a> $form: the view object</li>
				<li><span class="field">property:</span> <a href="../formapi/Model.html">Model</a> $model: the model object</li>
				<li><span class="field">author:</span> Zoltan Siki &lt;<a href="mailto:siki@agt.bme.hu">siki@agt.bme.hu</a>&gt; and Zoltan Koppanyi &lt;zoltan.koppanyi@gmail.com&gt;</li>
				<li><span class="field">version:</span> 0.1</li>
				<li><span class="field">see:</span> FormAPI::generate($lang, $full=1) could be used for generate the HTML code
 of form and @see FormAPI::request($request) for handling request. This class contains
 the view (@see FormAPI::$form) and model (@see FormAPI::$model) instances.</li>
			</ul>
		<p class="notes">
			Located in <a class="field" href="_formapi.php.html">/formapi.php</a> (line <span class="field">18</span>)
		</p>
		
				
		<pre></pre>
	
			</div>
</div>




	<a name="sec-method-summary"></a>
	<div class="info-box">
		<div class="info-box-title">Method Summary</span></div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
												<span class="disabled">Methods</span> (<a href="#sec-methods">details</a>)
		</div>
		<div class="info-box-body">			
			<div class="method-summary">
																												
												<div class="method-definition">
											<span class="method-result">FormAPI</span>
										<a href="#__construct" title="details" class="method-name">__construct</a>
											(<span class="var-type"><a href="../formapi/Form.html">Form</a></span>&nbsp;<span class="var-name">$form</span>, <span class="var-type"><a href="../formapi/Form.html">Form</a></span>&nbsp;<span class="var-name">$model</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">string</span>
										<a href="#generate" title="details" class="method-name">generate</a>
											(<span class="var-type">string</span>&nbsp;<span class="var-name">$lang</span>, [<span class="var-type">int</span>&nbsp;<span class="var-name">$full</span> = <span class="var-default">1</span>])
									</div>
																<div class="method-definition">
											<span class="method-result">string</span>
										<a href="#request" title="details" class="method-name">request</a>
											(<span class="var-type"><string,string></span>&nbsp;<span class="var-name">$request</span>)
									</div>
								</div>
		</div>
	</div>		

	
	<a name="sec-methods"></a>
	<div class="info-box">
		<div class="info-box-title">Methods</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
																<a href="#sec-method-summary">Methods</a> (<span class="disabled">details</span>)
						
		</div>
		<div class="info-box-body">
			<A NAME='method_detail'></A>

<a name="method__construct" id="__construct"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">Constructor __construct</span> (line <span class="line-number">30</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Constructor for initializing view and model objects</p>
	<ul class="tags">
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">FormAPI</span>
		<span class="method-name">
			__construct
		</span>
					(<span class="var-type"><a href="../formapi/Form.html">Form</a></span>&nbsp;<span class="var-name">$form</span>, <span class="var-type"><a href="../formapi/Form.html">Form</a></span>&nbsp;<span class="var-name">$model</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"><a href="../formapi/Form.html">Form</a></span>
				<span class="var-name">$form</span><span class="var-description">: view object</span>			</li>
					<li>
				<span class="var-type"><a href="../formapi/Form.html">Form</a></span>
				<span class="var-name">$model</span><span class="var-description">: model object</span>			</li>
				</ul>
		
			
	</div>
<a name="methodgenerate" id="generate"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">generate</span> (line <span class="line-number">43</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Generate form of HTML code</p>
	<ul class="tags">
				<li><span class="field">return:</span> HTML code of form</li>
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">string</span>
		<span class="method-name">
			generate
		</span>
					(<span class="var-type">string</span>&nbsp;<span class="var-name">$lang</span>, [<span class="var-type">int</span>&nbsp;<span class="var-name">$full</span> = <span class="var-default">1</span>])
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">string</span>
				<span class="var-name">$lang</span><span class="var-description">: language code, that has been defined in XML file of form</span>			</li>
					<li>
				<span class="var-type">int</span>
				<span class="var-name">$full</span><span class="var-description">: 0/1 generate only form/generate full html page</span>			</li>
				</ul>
		
			
	</div>
<a name="methodrequest" id="request"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">request</span> (line <span class="line-number">55</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Handling client request. This function responsible for validating responded values.</p>
	<ul class="tags">
				<li><span class="field">return:</span> message of model object after processing data</li>
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">string</span>
		<span class="method-name">
			request
		</span>
					(<span class="var-type"><string,string></span>&nbsp;<span class="var-name">$request</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"><string,string></span>
				<span class="var-name">$request</span><span class="var-description">: hashmap of the request in the following form: &lt;field_name, value&gt;</span>			</li>
				</ul>
		
			
	</div>
						
		</div>
	</div>


	<p class="notes" id="credit">
		Documentation generated on Sat, 01 Dec 2012 15:38:02 +0100 by <a href="http://www.phpdoc.org" target="_blank">phpDocumentor 1.4.4</a>
	</p>
	</div></body>
</html>